#ifndef __CTHREADSEM_H
#define __CTHREADSEM_H

#include <semaphore.h>

class CThreadSem
{
public:
  CThreadSem();
  CThreadSem(unsigned int uiVal);
  ~CThreadSem();
  
  int SemPost();
  int SemWait();
  int SemTryWait();
  int SemGetValue(int *iVal);

private:
  sem_t m_sem;
};

#endif